model
Class State

java.lang.Object
  extended by java.util.AbstractCollection<E>
      extended by java.util.AbstractList<E>
          extended by java.util.ArrayList<Individual>
              extended by model.State
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.lang.Iterable<Individual>, java.util.Collection<Individual>, java.util.List<Individual>, java.util.RandomAccess

public class State
extends java.util.ArrayList<Individual>
implements java.io.Serializable

Saves the global variables and the field lists to a state

Author:
See Also:
Serialized Form

Field Summary
 java.util.ArrayList<java.lang.Double> decisionpercent
          List of past iteration's decision percent
 java.util.ArrayList<java.lang.Double> experiencepercent
          List of past iteration's experience percent
 java.lang.String filename
          The file namespace the user is saving to
 java.util.ArrayList<java.lang.Double> gamepercentage
          List of past iteration's game percentage
 int iteration
          Number of week the simulation is running for
 java.util.ArrayList<java.lang.Double> numberoffriends
          List of past number of friends
 int numberofskiiers
          Number of peers simulated
 int numberofweeks
          The current week the simulation is on
 java.util.ArrayList<double[]> parksuccess
          Lists of past success of the simulated park
 boolean resort
          Equals true when the simulation is currently on resort mode, false if simulation is in individual mode
 java.util.ArrayList<java.lang.Double> skilllevel
          List of past iteration's skill level
 java.util.ArrayList<java.lang.Double> weather
          List of past iteration's weather
 
Constructor Summary
State(Details d)
          Constructor for State
 
Method Summary
 void refreshskiierstats()
          Cleans the field stats of the skiiers
 
Methods inherited from class java.util.ArrayList
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, get, indexOf, isEmpty, lastIndexOf, remove, remove, set, size, toArray, toArray, trimToSize
 
Methods inherited from class java.util.AbstractList
equals, hashCode, iterator, listIterator, listIterator, subList
 
Methods inherited from class java.util.AbstractCollection
containsAll, removeAll, retainAll, toString
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
containsAll, equals, hashCode, iterator, listIterator, listIterator, removeAll, retainAll, subList
 

Field Detail

iteration

public int iteration
Number of week the simulation is running for


parksuccess

public java.util.ArrayList<double[]> parksuccess
Lists of past success of the simulated park


numberofskiiers

public int numberofskiiers
Number of peers simulated


numberofweeks

public int numberofweeks
The current week the simulation is on


gamepercentage

public java.util.ArrayList<java.lang.Double> gamepercentage
List of past iteration's game percentage


weather

public java.util.ArrayList<java.lang.Double> weather
List of past iteration's weather


numberoffriends

public java.util.ArrayList<java.lang.Double> numberoffriends
List of past number of friends


experiencepercent

public java.util.ArrayList<java.lang.Double> experiencepercent
List of past iteration's experience percent


skilllevel

public java.util.ArrayList<java.lang.Double> skilllevel
List of past iteration's skill level


decisionpercent

public java.util.ArrayList<java.lang.Double> decisionpercent
List of past iteration's decision percent


filename

public java.lang.String filename
The file namespace the user is saving to


resort

public boolean resort
Equals true when the simulation is currently on resort mode, false if simulation is in individual mode

Constructor Detail

State

public State(Details d)
Constructor for State

Parameters:
d: - Text field input data from user
Method Detail

refreshskiierstats

public void refreshskiierstats()
Cleans the field stats of the skiiers